/**
 * 
 */
package us.gaaoc.framework.webapp.backingbeans.admin;

import java.util.Map;

import org.hibernate.Hibernate;

import us.gaaoc.framework.model.Person;
import us.gaaoc.framework.webapp.backingbeans.BaseBackingBean;

/**
 * @author Sukhada
 * Jun 22, 2006
 * GAJE_BibbCounty_1.0
 */
public class UserDetailsPage extends BaseBackingBean {

	/**
	 * Properties
	 */
	private Person personDetails;
	
	/**
	 * Constructor
	 *
	 */
	public UserDetailsPage() {
	}
	
	
	/**
	 * @return Returns the person.
	 */
	public Person getPersonDetails() {
		Hibernate.initialize(this.personDetails);
		return personDetails;
	}
	/**
	 * @param person The person to set.
	 */
	public void setPersonDetails(Person personDetails) {
		this.personDetails = personDetails;
	}
	
	public String deleteUser(){
		personDetails.setDeleteUserFlag((byte)1);
		this.getModelFacade().makePersistent(personDetails);
		return "deleteUser";
	}
	
	/**
	 * This method navigates user to the User Browser Page
	 * @return String
	 */
	public String gotoUserBrowser(){
		return "gotoUserBrowser";
	}
}
